package micro;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.system.ApplicationPidFileWriter;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.sleuth.zipkin.stream.EnableZipkinStreamServer;
import org.springframework.context.annotation.ComponentScan;
/**
 * @author txw
 * @version V1.0
 * @Title: Application
 * @ProjectName micro-sleuth-server
 * @Description: 描述
 * @since 2018/7/1 21:06
 */
@ComponentScan(basePackages = {
        "micro"
})
@EnableCaching
@SpringBootApplication
@EnableEurekaClient
@EnableZipkinStreamServer
public class Application {
    public static void main(String[] args){
        SpringApplication app = new SpringApplication(Application.class);
        app.addListeners(new ApplicationPidFileWriter("app.pid"));
        app.run(args);
    }
}
